#!/usr/bin/make -f

include /usr/share/cdbs/1/class/ant.mk
include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/rules/simple-patchsys.mk

JAVA_HOME            := /usr/lib/jvm/java-gcj
DEB_ANT_BUILDFILE    := debian/build.xml
DEB_JARS             := ant-nodeps laf-plugin xalan2
DEB_ANT_BUILD_TARGET := dist.pre
BUILDDIR             := build

makebuilddir/libskinlf-java-demo::
# The source package does not ship those two images (mandatory for the demo)
	convert debian/skinlfdemo.xpm src/examples/skinlfdemo.gif
	convert debian/windowicon.xpm src/examples/windowicon.gif 

install/libskinlf-java::
	install -m 644 -D $(BUILDDIR)/skinlf.jar debian/libskinlf-java/usr/share/java/skinlf-$(DEB_UPSTREAM_VERSION).jar
	ln -s skinlf-$(DEB_UPSTREAM_VERSION).jar debian/libskinlf-java/usr/share/java/skinlf.jar
	install -m 644 -D $(BUILDDIR)/nativeskin.jar debian/libskinlf-java/usr/share/java/nativeskin-$(DEB_UPSTREAM_VERSION).jar
	ln -s nativeskin-$(DEB_UPSTREAM_VERSION).jar debian/libskinlf-java/usr/share/java/nativeskin.jar

install/libskinlf-java-demo::
	install -m 644 -D $(BUILDDIR)/examples.jar debian/libskinlf-java-demo/usr/share/java/skinlf-demo-$(DEB_UPSTREAM_VERSION).jar
	ln -s  skinlf-demo-$(DEB_UPSTREAM_VERSION).jar debian/libskinlf-java-demo/usr/share/java/skinlf-demo.jar

get-orig-source:
	-uscan --upstream-version 0 --rename	
